Skip to content

Re-render a problem in the PG problem editor after a perltidy failure.#3015

Open
drgrice1 wants to merge 1 commit into
openwebwork:WeBWorK-2.21from
drgrice1:pgeditor-rerender-after-perltidy-failure
Open

Re-render a problem in the PG problem editor after a perltidy failure.#3015
drgrice1 wants to merge 1 commit into
openwebwork:WeBWorK-2.21from
drgrice1:pgeditor-rerender-after-perltidy-failure

Conversation

@drgrice1

Copy link
Copy Markdown
Member

When editing a problem and the code has a syntax error that prevents perltidy from working, if perltidy is then used it shows the errors from running perltidy. If you then fix those errors and run perltidy again, the toast shows that pertidy was successful, but the errors are still shown in the render window.

This pull request makes it so that when perltidy is successfully executed after a previous executing failed, then the problem is re-rendered, thus removing the perltidy errors. This is detected simply by checking if the render area contains an iframe or not.

This addresses issue #3012.

When editing a problem and the code has a syntax error that prevents
perltidy from working, if perltidy is then used it shows the errors from
running perltidy.  If you then fix those errors and run perltidy again,
the toast shows that pertidy was successful, but the errors are still
shown in the render window.

This pull request makes it so that when perltidy is successfully
executed after a previous executing failed, then the problem is
re-rendered, thus removing the perltidy errors.  This is detected simply
by checking if the render area contains an iframe or not.

This addresses issue openwebwork#3012.
@drgrice1 drgrice1 force-pushed the pgeditor-rerender-after-perltidy-failure branch from 8814507 to cbb1769 Compare June 11, 2026 10:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant